home *** CD-ROM | disk | FTP | other *** search
/ MacWorld 1999 November / Macworld (1999-11).dmg / Updaters / WhiteCap 3.0.4 / WhiteCap Source.sit / WhiteCap Source / SJ SDK / SoundJamAPI.h < prev    next >
Text File  |  1999-08-06  |  20KB  |  631 lines

  1. /*
  2.     File:        SoundJamAPI.h
  3.  
  4.     Contains:    
  5.  
  6.     Written by:    Jeff Robbin
  7.  
  8.     Copyright:    Copyright ©1998 Jeff Robbin
  9. */
  10.  
  11.  
  12. #pragma once
  13.  
  14. #include <Types.h>
  15. #include <Files.h>
  16. #include <OSUtils.h>
  17. #include <Quickdraw.h>
  18. #include <Sound.h>
  19.  
  20. #if PRAGMA_STRUCT_ALIGN
  21.     #pragma options align=power
  22. #endif
  23.  
  24. #ifdef __cplusplus
  25. extern "C" {
  26. #endif
  27.  
  28. enum {
  29.     kCurrentPluginMessageVersion = 8
  30. };
  31.  
  32. enum {
  33.     /* Track Kind */
  34.     
  35.     kFileKind        = 'FILE',
  36.     kCDKind            = 'CD  ',
  37.     kDeviceKind        = 'DEV ',
  38.     kHTTPKind        = 'HTTP',
  39.     kSoundInputKind    = 'SINP'
  40. };
  41.  
  42. #define    kMaxURLSize    512
  43.  
  44. enum {
  45.     // TrackHeader flags
  46.     
  47.     kTrackSupportsID3Tags    = (1L << 0)            /* Can have ID3 information tags. */
  48. };
  49.  
  50. struct TrackHeader {
  51.     Str63            name;
  52.     Str63            artist;
  53.     Str63            album;
  54.     
  55.     Str63            notice;
  56.     
  57.     Str63            kind;
  58.     
  59.     Str63            genre;
  60.     
  61.     Str63            url;
  62.     
  63.     UInt32            trackNumber;
  64.     UInt32            numTracks;
  65.     
  66.     UInt32            validFlags;
  67.     UInt32            flags;
  68.     
  69.     SInt16            year;
  70.     
  71.     UInt8            reserved[62];
  72. };
  73. typedef struct TrackHeader TrackHeader;
  74.  
  75. struct FileLocation {
  76.     FSSpec                spec;
  77.     FInfo                fInfo;
  78. };
  79. typedef struct FileLocation FileLocation;
  80.  
  81. struct HTTPLocation {
  82.     UInt32                length;
  83.     UInt8                url[kMaxURLSize];
  84. };
  85. typedef struct HTTPLocation HTTPLocation;
  86.  
  87. struct CDPositioning {
  88.     UInt8                minute;
  89.     UInt8                second;
  90.     UInt8                frame;
  91. };
  92. typedef struct CDPositioning CDPositioning;
  93.  
  94. struct CDLocation {
  95.     SInt16                vRefNum;
  96.     SInt16                dRefNum;
  97.     SInt16                trackNumber;
  98.     CDPositioning        baseTimePosition;
  99.     CDPositioning        endTimePosition;
  100.     UInt32                baseTimeInMS;
  101.     UInt32                numFrames;
  102. };
  103. typedef struct CDLocation CDLocation;
  104.  
  105. struct SoundInputLocation {
  106.     Str255                inputDevice;
  107. };
  108. typedef struct SoundInputLocation SoundInputLocation;
  109.  
  110. union TrackLocation {
  111.     FileLocation        file;
  112.     HTTPLocation        http;
  113.     CDLocation            cd;
  114.     SoundInputLocation    soundIn;
  115. };
  116. typedef union TrackLocation TrackLocation;
  117.  
  118. enum {
  119.     /* playOptions */
  120.     
  121.     kTrackCanBeLiveSeeked        = (1L << 0),        /* Can handle rapid position messages */
  122.     kTrackCanBeExtracted        = (1L << 1),        /* Can support extraction messages. */
  123.     kTrackCanBeDecoded            = (1L << 2)            /* Can support decode messages. */
  124. };
  125.  
  126. struct TrackSpec {
  127.     Str255                name;
  128.     Str255                artist;
  129.     Str255                album;
  130.     
  131.     Str255                genre;
  132.     
  133.     UInt32                trackKind;
  134.     TrackLocation        location;
  135.     
  136.     UInt32                trackID;
  137.     UInt32                trackNumber;
  138.  
  139.     UInt32                totalTimeInMS;
  140.     OptionBits            playOptions;
  141. };
  142. typedef struct TrackSpec TrackSpec;
  143.  
  144. enum {
  145.     /* Plugin (main) messages */
  146.     
  147.     kPluginNullMessage                    = 'null',
  148.  
  149.     kPluginInitializeMessage            = 'init',
  150.     kPluginCleanupMessage                = 'clr ',
  151.     
  152.     kPluginIdleMessage                    = 'idle'
  153. };
  154.  
  155.  
  156. enum {
  157.     /* SoundJamAPI messages */
  158.     
  159.     kPlayerIdleMessage                    = 'idle',    /* Give the player some time */
  160.     kPlayerUnregisterPluginMessage        = 'unrg',    /* Unregister the plugin this comes from */
  161.     
  162.     kPlayerSetPreferenceMessage            = 'sprf',    /* Set a preference */
  163.     kPlayerGetPreferenceMessage            = 'gprf',    /* Get a preference */
  164.     
  165.     kPlayerSetFullScreenMessage            = 'sful',    /* Set full screen mode */
  166.     kPlayerSetFullScreenOptionsMessage    = 'sfop',    /* Set full screen options */
  167.     
  168.     kPlayerSetDefaultWindowSizeMessage    = 'sdef',    /* Set default window size */
  169.     
  170.     kPlayerDoneTrackMessage                = 'done',    /* Currently playing track finished. */
  171.     kPlayerPlayTrackMessage                = 'play',    /* Clicked the play button */
  172.     kPlayerStopTrackMessage                = 'stop',    /* Clicked the stop button */
  173.     kPlayerPauseTrackMessage            = 'paus',    /* Clicked the pause button */
  174.     kPlayerNextTrackMessage                = 'next',    /* Go to the next track */
  175.     kPlayerPrevTrackMessage                = 'prev',    /* Go to the prev track */
  176.     kPlayerLoadTrackMessage                = 'load',    /* Load a track with Standard File */
  177.     
  178.     kPlayerShowHideEQMessage            = 'eq  ',    /* Show or hide the eq window */
  179.     kPlayerShowHidePlaylistMessage        = 'pl  ',    /* Show or hide the current playlist */
  180.     
  181.     kPlayerOpenPrefsMessage                = 'oprf',    /* Open the preferences dialog */
  182.     kPlayerCloseWindowMessage            = 'clos',    /* Close the window */
  183.     kPlayerMinimizeWindowMessage        = 'minw',    /* Minimize the window */
  184.     
  185.     kPlayerSetTrackPositionMessage        = 'spos',    /* Set the position */
  186.  
  187.     kPlayerSetVolumeBalanceMessage        = 'svol',    /* Set the volume and balance */
  188.  
  189.     kPlayerSetTrebleBassMessage            = 'stb ',    /* Set the treble and bass */
  190.  
  191.     kPlayerSetEQLevelMessage            = 'seql',    /* Set the eq level for a band. */
  192.     kPlayerSetEQOptionsMessage            = 'seqo',    /* Set the eq options. */
  193.     
  194.     kPlayerPopupEQPresetsMenuMessage    = 'eqpr',    /* Popup the EQ presets menu. */
  195.     
  196.     kPlayerShowAboutMessage                = 'abou',    /* Show the about box. */
  197.     kPlayerOpenURLMessage                = 'url ',    /* Open a URL */
  198.     
  199.     kPlayerDragWindowMessage            = 'drag',    /* Drag a window */
  200.     
  201.     kPlayerDecodeDoneMessage            = 'ddcd',    /* Play some data (INTERRUPT-SAFE from Player plugin). */
  202.     kPlayerInstallDeferredTaskMessage    = 'indt',    /* Install a deferredTask (INTERRUPT-SAFE from Player plugin). */
  203.     
  204.     kPlayerExtractProgressMessage        = 'extp',    /* Report on the progress of the extract */
  205.     
  206.     kPlayerRegisterVisualPluginMessage    = 'rvis',    /* Register a visual plugin */
  207.     kPlayerRegisterPlayerPluginMessage    = 'rply',    /* Register a player plugin */
  208.     kPlayerRegisterEncoderPluginMessage    = 'renc',    /* Register an encoder plugin */
  209.     kPlayerRegisterSkinPluginMessage    = 'rskn',    /* Register a skin plugin */
  210.     kPlayerRegisterDevicePluginMessage    = 'rdev',    /* Register a device plugin */
  211.         
  212.     kPlayerSetPluginDataMessage            = 'sprf',    /* Set plugin preferences */
  213.     kPlayerGetPluginDataMessage            = 'gprf'    /* Get plugin preferences */
  214. };
  215.  
  216.  
  217. enum {
  218.     /* Plugin (main) options */
  219.     
  220.     kKeepPluginResourceForkOpen = (1L << 0),    /* Keep the plugin resource fork open */
  221.                                                 /* beyond the initialization message. */
  222.     kPluginWantsIdleMessages    = (1L << 1),
  223.     kPluginWantsToBeLeftOpen    = (1L << 2)        /* Don't close this plugin just because */
  224.                                                 /* he didn't register anyone */
  225. };
  226.  
  227.  
  228. typedef OSStatus (*SoundJamProcPtr)(void *appCookie, OSType message, struct PlayerMessageInfo *messageInfo);
  229.  
  230.  
  231. /*
  232.     Plugin main Messages
  233. */
  234.  
  235. struct PluginInitMessage {
  236.     UInt32                            version;                /* Input */
  237.  
  238.     void *                            appCookie;                /* Input */
  239.     SoundJamProcPtr                    playerProc;                /* Input */
  240.     
  241.     OptionBits                        options;                /* Output */
  242.     void *                            refcon;                    /* Output */
  243. };
  244. typedef struct PluginInitMessage PluginInitMessage;
  245.  
  246. struct PluginMessageInfo {
  247.     union {
  248.         PluginInitMessage            initMessage;
  249.     } u;
  250. };
  251. typedef struct PluginMessageInfo PluginMessageInfo;
  252.  
  253.  
  254.  
  255. /* Plugin main. */
  256. typedef OSStatus (*PluginProcPtr)(OSType message, PluginMessageInfo *messageInfo, void *refcon);
  257.  
  258. typedef OSStatus (*PlayerPluginProcPtr)(OSType message, struct PlayerPluginMessageInfo *messageInfo, void *refcon);
  259. typedef OSStatus (*VisualPluginProcPtr)(OSType message, struct VisualPluginMessageInfo *messageInfo, void *refcon);
  260. typedef OSStatus (*EncoderPluginProcPtr)(OSType message, struct EncoderPluginMessageInfo *messageInfo, void *refcon);
  261. typedef OSStatus (*SkinPluginProcPtr)(OSType message, struct SkinPluginMessageInfo *messageInfo, void *refcon);
  262. typedef OSStatus (*DevicePluginProcPtr)(OSType message, struct DevicePluginMessageInfo *messageInfo, void *refcon);
  263.  
  264.  
  265.  
  266. /*
  267.     Exported interfaces from the Player
  268. */
  269.  
  270. enum {
  271.     kRepeatOff    = 0,
  272.     kRepeatAllTracks,
  273.     kRepeatOneTrack
  274. };
  275.  
  276. enum {
  277.     /* Preferences */
  278.     
  279.     kPrefSetTimeDisplay                    = 'stim',    /* Set the time display mode */
  280.     kPrefShuffleTracks                    = 'shuf',    /* Shuffle tracks Off/On (0 or 1) */
  281.     kPrefRepeatTracks                    = 'rept',    /* Repeat tracks (see enum). */
  282.     kPrefDisplayTrackNumber                = 'dtrk'    /* Display the track number */
  283. };
  284.  
  285. enum {
  286.     /* EQ Options */
  287.     
  288.     kEQEnabled        = (1L << 0),
  289.     kEQAuto            = (1L << 1)
  290. };
  291.  
  292. enum {
  293.     /* Tone Options */
  294.     
  295.     kToneEnabled    = (1L << 0)
  296. };
  297.  
  298. enum {
  299.     /* RegisterVisualMessage.options */
  300.     
  301.     kVisualRequiresFullScreen            = (1L << 0),
  302.     kVisualForBuiltIn                    = (1L << 1),
  303.     kVisualIsResizeable                    = (1L << 2),
  304.     kVisualWantsIdleMessages            = (1L << 3),
  305.     kVisualWantsToProcessSamples        = (1L << 4),
  306.     kVisualWantsConfigure                = (1L << 5),
  307.     kVisualWantsAbout                    = (1L << 6),
  308.     kVisualEnabledByDefault                = (1L << 7)
  309. };
  310.  
  311. enum {
  312.     /* RegisterPlayerMessage.options */
  313.     kPlayerWantsIdleMessages            = (1L << 0)
  314. };
  315.  
  316. enum {
  317.     /* RegisterEncoderMessage.options */
  318.     kEncoderWantsIdleMessages            = (1L << 0)
  319. };
  320.  
  321. enum {
  322.     /* RegisterSkinMessage.options */
  323.     kSkinWantsIdleMessages                = (1L << 0)
  324. };
  325.  
  326. enum {
  327.     /* RegisterDeviceMessage.options */
  328.     kDeviceWantsIdleMessages            = (1L << 0)
  329. };
  330.  
  331. struct PlayerPreferenceMessage {
  332.     OSType                            preference;
  333.     UInt32                            value;
  334. };
  335. typedef struct PlayerPreferenceMessage PlayerPreferenceMessage;
  336.  
  337. struct PlayerSetFullScreenMessage {
  338.     Boolean                            fullScreen;
  339. };
  340. typedef struct PlayerSetFullScreenMessage PlayerSetFullScreenMessage;
  341.  
  342. struct PlayerSetFullScreenOptionsMessage {
  343.     SInt16                            minBitDepth;
  344.     SInt16                            maxBitDepth;
  345.     SInt16                            preferredBitDepth;
  346.     
  347.     SInt16                            desiredWidth;
  348.     SInt16                            desiredHeight;
  349. };
  350. typedef struct PlayerSetFullScreenOptionsMessage PlayerSetFullScreenOptionsMessage;
  351.  
  352. struct PlayerSetDefaultWindowSizeMessage {
  353.     SInt16                            defaultWidth;
  354.     SInt16                            defaultHeight;
  355.     
  356.     SInt16                            minWidth;
  357.     SInt16                            minHeight;
  358.  
  359.     SInt16                            maxWidth;
  360.     SInt16                            maxHeight;    
  361. };
  362. typedef struct PlayerSetDefaultWindowSizeMessage PlayerSetDefaultWindowSizeMessage;
  363.  
  364. struct PlayerShowHideMessage {
  365.     Boolean                            showWindow;
  366. };
  367. typedef struct PlayerShowHideMessage PlayerShowHideMessage;
  368.  
  369. struct PlayerDecodeDoneMessage {
  370.     void *                            playerCookie;
  371.     OSStatus                        readStatus;
  372.     OSStatus                        decodeStatus;
  373.     UInt32                            numSamples;
  374. };
  375. typedef struct PlayerDecodeDoneMessage PlayerDecodeDoneMessage;
  376.  
  377. struct PlayerExtractProgressMessage {
  378.     void *                            extractCookie;
  379.     UInt32                            progressInMS;
  380. };
  381. typedef struct PlayerExtractProgressMessage PlayerExtractProgressMessage;
  382.  
  383. struct PlayerSetTrackPositionMessage {
  384.     UInt32                            positionInMS;
  385. };
  386. typedef struct PlayerSetTrackPositionMessage PlayerSetTrackPositionMessage;
  387.  
  388. struct PlayerSetVolumeBalanceMessage {
  389.     SInt32                            volume;        /* 0-0x100 |  0-0x100 ((Right << 16) | Left) */
  390.     SInt32                            balance;    /* 0-100 (Left to Right) */
  391. };
  392. typedef struct PlayerSetVolumeBalanceMessage PlayerSetVolumeBalanceMessage;
  393.  
  394. struct PlayerSetTrebleBassMessage {
  395.     SInt32                            treble;        /* -100 - 100 */
  396.     SInt32                            bass;        /* -100 - 100 */
  397. };
  398. typedef struct PlayerSetTrebleBassMessage PlayerSetTrebleBassMessage;
  399.  
  400. struct PlayerSetEQLevelMessage {
  401.     UInt32                            band;        /* 0-9 */
  402.     UInt32                            level;        /* 0-2400 */
  403. };
  404. typedef struct PlayerSetEQLevelMessage PlayerSetEQLevelMessage;
  405.  
  406. struct PlayerSetEQOptionsMessage {
  407.     OptionBits                        options;
  408. };
  409. typedef struct PlayerSetEQOptionsMessage PlayerSetEQOptionsMessage;
  410.  
  411. struct PlayerPopupEQPresetsMenuMessage {
  412.     Point                            localPt;
  413. };
  414. typedef struct PlayerPopupEQPresetsMenuMessage PlayerPopupEQPresetsMenuMessage;
  415.  
  416. struct PlayerOpenURLMessage {
  417.     SInt8 *                            url;
  418.     UInt32                            length;
  419. };
  420. typedef struct PlayerOpenURLMessage PlayerOpenURLMessage;
  421.  
  422. struct PlayerCloseWindowMessage {
  423.     WindowPtr                        window;
  424. };
  425. typedef struct PlayerCloseWindowMessage PlayerCloseWindowMessage;
  426.  
  427. struct PlayerMinimizeWindowMessage {
  428.     WindowPtr                        window;
  429.     Boolean                            minimized;
  430. };
  431. typedef struct PlayerMinimizeWindowMessage PlayerMinimizeWindowMessage;
  432.  
  433. struct PlayerDragWindowMessage {
  434.     WindowPtr                        window;
  435.     Point                            globalWhere;
  436. };
  437. typedef struct PlayerDragWindowMessage PlayerDragWindowMessage;
  438.  
  439. struct PlayerRegisterPlayerPluginMessage {
  440.     /* Input from plugin */
  441.     
  442.     Str63                            name;
  443.     OptionBits                        options;
  444.     
  445.     UInt32                            messageVersion;
  446.     PlayerPluginProcPtr                handler;
  447.     void *                            registerRefcon;
  448. };
  449. typedef struct PlayerRegisterPlayerPluginMessage PlayerRegisterPlayerPluginMessage;
  450.  
  451. struct PlayerRegisterVisualPluginMessage {
  452.     /* Input from plugin */
  453.     
  454.     Str63                            name;
  455.     OptionBits                        options;
  456.     
  457.     UInt32                            messageVersion;
  458.     VisualPluginProcPtr                handler;
  459.     void *                            registerRefcon;
  460.  
  461.     UInt32                            timeBetweenDataInMS;
  462.     UInt32                            numWaveformChannels;
  463.     UInt32                            numSpectrumChannels;
  464.     
  465.     SInt16                            minWidth;                    /* For backward compatibility with 1.0 only (default window size) */
  466.     SInt16                            minHeight;                    /* For backward compatibility with 1.0 only (default window size) */
  467.     
  468.     SInt16                            maxWidth;                    /* For backward compatibility with 1.0 only (should not be really large) */
  469.     SInt16                            maxHeight;                    /* For backward compatibility with 1.0 only (should not be really large) */
  470.     
  471.                                                                 /* Call PlayerSetDefaultWindowSize from */
  472.                                                                 /* the initializeMessage in the visual plugin */
  473.                                                                 /* handler to set the resizable min/max width & height. */
  474.     
  475.     UInt16                            minFullScreenBitDepth;        /* 0 = Any */
  476.     UInt16                            maxFullScreenBitDepth;        /* 0 = Any */
  477.     
  478.     UInt16                            windowAlignmentInBytes;        /* 0 = Any */
  479. };
  480. typedef struct PlayerRegisterVisualPluginMessage PlayerRegisterVisualPluginMessage;
  481.  
  482. struct PlayerRegisterEncoderPluginMessage {
  483.     /* Input from plugin */
  484.     
  485.     Str63                            name;
  486.     OptionBits                        options;
  487.     
  488.     UInt32                            messageVersion;
  489.     EncoderPluginProcPtr            handler;
  490.     void *                            registerRefcon;
  491. };
  492. typedef struct PlayerRegisterEncoderPluginMessage PlayerRegisterEncoderPluginMessage;
  493.  
  494. struct PlayerRegisterSkinPluginMessage {
  495.     /* Input from plugin */
  496.     
  497.     Str63                            name;
  498.     OptionBits                        options;
  499.     
  500.     UInt32                            messageVersion;
  501.     SkinPluginProcPtr                handler;
  502.     void *                            registerRefcon;
  503. };
  504. typedef struct PlayerRegisterSkinPluginMessage PlayerRegisterSkinPluginMessage;
  505.  
  506. struct PlayerRegisterDevicePluginMessage {
  507.     /* Input from plugin */
  508.     
  509.     Str63                            name;
  510.     OptionBits                        options;
  511.     
  512.     UInt32                            messageVersion;
  513.     DevicePluginProcPtr                handler;
  514.     void *                            registerRefcon;
  515.     
  516.     PicHandle                        logoPicture;
  517.     UInt8 *                            logoURL;
  518. };
  519. typedef struct PlayerRegisterDevicePluginMessage PlayerRegisterDevicePluginMessage;
  520.  
  521. struct PlayerCreateDeviceWindowMessage {
  522.     void *                            handlerData;    // DeviceHandlerData
  523. };
  524. typedef struct PlayerCreateDeviceWindowMessage PlayerCreateDeviceWindowMessage;
  525.  
  526. struct PlayerInstallDeferredTaskMessage {
  527.     DeferredTask *                    deferredTask;
  528. };
  529. typedef struct PlayerInstallDeferredTaskMessage PlayerInstallDeferredTaskMessage;
  530.  
  531. struct PlayerSetPluginDataMessage {
  532.     void *                            dataPtr;
  533.     UInt32                            dataSize;
  534. };
  535. typedef struct PlayerSetPluginDataMessage PlayerSetPluginDataMessage;
  536.  
  537. struct PlayerGetPluginDataMessage {
  538.     void *                            dataPtr;        /* Input */
  539.     UInt32                            dataBufferSize;    /* Input */
  540.     
  541.     UInt32                            dataSize;        /* Output */
  542. };
  543. typedef struct PlayerGetPluginDataMessage PlayerGetPluginDataMessage;
  544.  
  545. struct PlayerMessageInfo {
  546.     UInt32                                    version;
  547.     union {
  548.         PlayerPreferenceMessage                preferenceMessage;
  549.         PlayerSetFullScreenMessage            setFullScreenMessage;
  550.         PlayerSetFullScreenOptionsMessage    setFullScreenOptionsMessage;
  551.         PlayerSetDefaultWindowSizeMessage    setDefaultWindowSizeMessage;
  552.         PlayerShowHideMessage                showHideMessage;
  553.         PlayerDecodeDoneMessage                decodeDoneMessage;
  554.         PlayerExtractProgressMessage        extractProgressMessage;
  555.         PlayerInstallDeferredTaskMessage    installDeferredTaskMessage;
  556.         PlayerSetTrackPositionMessage        setTrackPositionMessage;
  557.         PlayerSetVolumeBalanceMessage        setVolumeBalanceMessage;
  558.         PlayerSetTrebleBassMessage            setTrebleBassMessage;
  559.         PlayerSetEQLevelMessage                setEQLevelMessage;
  560.         PlayerSetEQOptionsMessage            setEQOptionsMessage;
  561.         PlayerPopupEQPresetsMenuMessage        popupEQPresetsMenuMessage;
  562.         PlayerOpenURLMessage                openURLMessage;
  563.         PlayerCloseWindowMessage            closeWindowMessage;
  564.         PlayerMinimizeWindowMessage            minimizeWindowMessage;
  565.         PlayerDragWindowMessage                dragWindowMessage;
  566.         PlayerGetPluginDataMessage            getPluginDataMessage;
  567.         PlayerSetPluginDataMessage            setPluginDataMessage;
  568.         PlayerRegisterVisualPluginMessage    registerVisualPluginMessage;
  569.         PlayerRegisterPlayerPluginMessage    registerPlayerPluginMessage;
  570.         PlayerRegisterEncoderPluginMessage    registerEncoderPluginMessage;
  571.         PlayerRegisterSkinPluginMessage        registerSkinPluginMessage;
  572.         PlayerRegisterDevicePluginMessage    registerDevicePluginMessage;
  573.     } u;
  574. };
  575. typedef struct PlayerMessageInfo PlayerMessageInfo;
  576.  
  577. extern OSStatus PlayerIdle (void *appCookie, SoundJamProcPtr playerHandler);
  578. extern OSStatus PlayerSetPreference (void *appCookie, SoundJamProcPtr playerHandler, OSType preference, UInt32 value);
  579. extern OSStatus PlayerGetPreference (void *appCookie, SoundJamProcPtr playerHandler, OSType preference, UInt32 *value);
  580. extern OSStatus PlayerSetFullScreen (void *appCookie, SoundJamProcPtr playerHandler, Boolean fullScreen);
  581. extern OSStatus PlayerSetFullScreenOptions (void *appCookie, SoundJamProcPtr playerHandler, SInt16 minBitDepth, SInt16 maxBitDepth, SInt16 preferredBitDepth, SInt16 desiredWidth, SInt16 desiredHeight);
  582. extern OSStatus PlayerSetDefaultWindowSize (    void *            appCookie,
  583.                                                 SoundJamProcPtr    playerHandler,
  584.                                                 SInt16            defaultWidth,
  585.                                                 SInt16            defaultHeight,
  586.                                                 SInt16            minWidth,
  587.                                                 SInt16            minHeight,
  588.                                                 SInt16            maxWidth,
  589.                                                 SInt16            maxHeight);
  590. extern void        PlayerShowHideEQWindow (void *appCookie, SoundJamProcPtr playerHandler, Boolean showWindow);
  591. extern void        PlayerShowHidePlaylistWindow (void *appCookie, SoundJamProcPtr playerHandler, Boolean showWindow);
  592. extern OSStatus PlayerDoneTrack (void *appCookie, SoundJamProcPtr playerHandler);
  593. extern OSStatus PlayerNextTrack (void *appCookie, SoundJamProcPtr playerHandler);
  594. extern OSStatus PlayerPrevTrack (void *appCookie, SoundJamProcPtr playerHandler);
  595. extern OSStatus PlayerPlayTrack (void *appCookie, SoundJamProcPtr playerHandler);
  596. extern OSStatus PlayerStopTrack (void *appCookie, SoundJamProcPtr playerHandler);
  597. extern OSStatus PlayerPauseTrack (void *appCookie, SoundJamProcPtr playerHandler);
  598. extern OSStatus PlayerLoadTrack (void *appCookie, SoundJamProcPtr playerHandler);
  599. extern OSStatus    PlayerSetTrackPosition (void *appCookie, SoundJamProcPtr playerHandler, UInt32 positionInMS);
  600. extern OSStatus PlayerSetVolumeBalance (void *appCookie, SoundJamProcPtr playerHandler, SInt32 volume, SInt32 balance);
  601. extern OSStatus PlayerSetTrebleBass (void *appCookie, SoundJamProcPtr playerHandler, SInt32 treble, SInt32 bass);
  602. extern void        PlayerShowAbout (void *appCookie, SoundJamProcPtr playerHandler);
  603. extern void        PlayerOpenURL (void *appCookie, SoundJamProcPtr playerHandler, SInt8 *string, UInt32 length);
  604. extern OSStatus PlayerSetEQLevel (void *appCookie, SoundJamProcPtr playerHandler, UInt32 band, SInt32 level);
  605. extern OSStatus PlayerSetEQOptions (void *appCookie, SoundJamProcPtr playerHandler, OptionBits options);
  606. extern OSStatus PlayerPopupEQPresetsMenu (void *appCookie, SoundJamProcPtr playerHandler, Point localPt);
  607. extern void        PlayerDragWindow (void *appCookie, SoundJamProcPtr playerHandler, WindowPtr window, Point globalWhere);
  608. extern OSStatus    PlayerGetPluginData (void *appCookie, SoundJamProcPtr playerHandler, void *dataPtr, UInt32 dataBufferSize, UInt32 *dataSize);
  609. extern OSStatus    PlayerSetPluginData (void *appCookie, SoundJamProcPtr playerHandler, void *dataPtr, UInt32 dataSize);
  610. extern void        PlayerOpenPrefs (void *appCookie, SoundJamProcPtr playerHandler);
  611. extern void        PlayerCloseWindow (void *appCookie, SoundJamProcPtr playerHandler, WindowPtr window);
  612. extern void        PlayerMinimizeWindow (void *appCookie, SoundJamProcPtr playerHandler, WindowPtr window, Boolean isMinimized);
  613. extern void        PlayerDecodeDone (void *appCookie, SoundJamProcPtr playerHandler, void *playerCookie, OSStatus readStatus, OSStatus decodeStatus, UInt32 numSamples);
  614. extern OSStatus PlayerExtractProgress (void *appCookie, SoundJamProcPtr playerHandler, void *extractCookie, UInt32 progressInMS);
  615. extern OSStatus PlayerRegisterVisualPlugin (void *appCookie, SoundJamProcPtr playerHandler, PlayerMessageInfo *messageInfo);
  616. extern OSStatus PlayerRegisterPlayerPlugin (void *appCookie, SoundJamProcPtr playerHandler, PlayerMessageInfo *messageInfo);
  617. extern OSStatus PlayerRegisterEncoderPlugin (void *appCookie, SoundJamProcPtr playerHandler, PlayerMessageInfo *messageInfo);
  618. extern OSStatus PlayerRegisterSkinPlugin (void *appCookie, SoundJamProcPtr playerHandler, PlayerMessageInfo *messageInfo);
  619. extern OSStatus PlayerRegisterDevicePlugin (void *appCookie, SoundJamProcPtr playerHandler, PlayerMessageInfo *messageInfo);
  620. extern OSStatus    PlayerUnregisterPlugin (void *appCookie, SoundJamProcPtr playerHandler, PlayerMessageInfo *messageInfo);
  621. extern OSStatus PlayerInstallDeferredTask (void *appCookie, SoundJamProcPtr playerHandler, DeferredTask *dTask);
  622.  
  623. #if PRAGMA_STRUCT_ALIGN
  624.     #pragma options align=reset
  625. #endif
  626.  
  627. #ifdef __cplusplus
  628. }
  629. #endif
  630.  
  631.